import { Component, OnInit, ViewEncapsulation } from '@angular/core';
import { GridOptions } from 'ag-grid/main';
import { RestService } from './../../services/rest.service';

import * as _ from 'lodash';

@Component({
  selector: 'app-discover',
  templateUrl: './discover.component.html',
  styleUrls: ['./discover.component.css'],
  encapsulation: ViewEncapsulation.None
})
export class DiscoverComponent implements OnInit {
  table1: any;
  table11: any;
  table12: any;
  table13: any;
  table14: any;
  table2: any;
  table21: any;
  table22: any;
  table23: any;
  table24: any;
  table3: any;
  table32: any;
  table4: any;
  table42: any;
  table43: any;
  table5: any;
  table52: any;
  table53: any;
  table54: any;
  table55: any;
  table56: any;
  table57: any;
  table58: any;
  table59: any;

  constructor(public restService: RestService) {
    this.table1 = this.restService.getTable('FC_1');
    this.table11 = this.restService.getTable('FC_11');
    this.table12 = this.restService.getTable('FC_12');
    this.table13 = this.restService.getTable('FC_13');
    this.table14 = this.restService.getTable('FC_14');
    this.table2 = this.restService.getTable('FC_2');
    this.table21 = this.restService.getTable('FC_21');
    this.table22 = this.restService.getTable('FC_22');
    this.table23 = this.restService.getTable('FC_23');
    this.table24 = this.restService.getTable('FC_24');
    this.table3 = this.restService.getTable('DCDC');
    this.table32 = this.restService.getTable('DCDC2');
    this.table4 = this.restService.getTable('BMS');
    this.table42 = this.restService.getTable('BMS2');
    this.table43 = this.restService.getTable('BMS3');
    this.table5 = this.restService.getTable('ECU1');
    this.table52 = this.restService.getTable('ECU2');
    this.table53 = this.restService.getTable('ECU3');
    this.table54 = this.restService.getTable('ECU4');
    this.table55 = this.restService.getTable('ECU5');
    this.table56 = this.restService.getTable('ECU6');
    this.table57 = this.restService.getTable('ECU7');
    this.table58 = this.restService.getTable('ECU8');
    this.table59 = this.restService.getTable('ECU9');
  }

  ngOnInit() {
  }
}
